snit::widget ScrolledText {

  hulltype ttk::frame
  option -borderwidth 0

  constructor {args} {
    $self configurelist $args
    $hull configure -borderwidth $options(-borderwidth)
    text $self.text -xscrollcommand "$self.horizontalScrollBar set" \
        -yscrollcommand "$self.verticalScrollBar set"
    ttk::scrollbar $self.verticalScrollBar -command "$self.text yview"
    ttk::scrollbar $self.horizontalScrollBar -orient horizontal \
        -command "$self.text xview"
    grid $self.text $self.verticalScrollBar -sticky nswe
    grid $self.horizontalScrollBar -sticky we
    grid rowconfigure $self 0 -weight 1
    grid rowconfigure $self 1 -weight 0
    grid columnconfigure $self 0 -weight 1
    grid columnconfigure $self 1 -weight 0
  }

}

